import java.io.*;
//二进制文件转文本文件
public class CharUtiltx {
    public static void dump(Reader src, Writer dest) throws IOException {
        try(Reader input = src; Writer output = dest) {
            char[] data = new char[1];
            while((input.read(data)) != -1) {
                int da=(int)data[0];
                String str1="";
                String str=Integer.toBinaryString(da);
                for(int i=0;i<8;i++)
                {
                    if(i<(8-str.length()))str1+='0';

                }
                str1+=str;
                output.write(str1, 0, 8);
                output.write(" ");
            }
        }
    }
}
public class CharUtilxt {
    public static void dump(Reader src, Writer dest) throws IOException {
        try(Reader input = src; Writer output = dest) {
            char[] data = new char[8];
            char []ch = new char[1];

            while((input.read(data)) != -1) {
                String str="";
                for(int i=0;i<8;i++)
                {
                    str+=data[i];
                }
                int ten=Integer.valueOf(str,2);
                ch[0]=(char)ten;
                output.write(ch, 0, 1);
                output.write(" ");
            }
        }
    }
}
